package cn.iocoder.yudao.module.erp.controller.admin.purpurchaseorderitem.vo;

import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;

@Schema(description = "管理后台 - ERP 采购单项 Response VO")
@Data
@ExcelIgnoreUnannotated
public class PurPurchaseOrderItemRespVO {

    @Schema(description = "编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "30746")
    @ExcelProperty("编号")
    private Long id;

    @Schema(description = "采购单编号-提交供应商采购单编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "15765")
    @ExcelProperty("采购单编号-提交供应商采购单编号")
    private String purchaseOrderId;

    @Schema(description = "产品编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "25464")
    @ExcelProperty("产品编号")
    private Long productId;

    @Schema(description = "产品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "25464")
    @ExcelProperty("产品名称")
    private String productName;

    @Schema(description = "产品单位", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty(value = "产品单位", converter = DictConvert.class)
    @DictFormat("product_unit") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Long productUnit;

    @Schema(description = "产品规格", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("产品规格")
    private String productStandards;

    @Schema(description = "产品单价", requiredMode = Schema.RequiredMode.REQUIRED, example = "27415")
    @ExcelProperty("产品单价")
    private BigDecimal productPrice;

    @Schema(description = "数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "31411")
    @ExcelProperty("数量")
    private BigDecimal count;
    @Schema(description = "数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "31411")
    @ExcelProperty("数量")
    private BigDecimal countIn;    @Schema(description = "数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "31411")
    @ExcelProperty("数量")
    private BigDecimal countOut;




    @Schema(description = "总价", requiredMode = Schema.RequiredMode.REQUIRED, example = "3841")
    @ExcelProperty("总价")
    private BigDecimal totalPrice;

    @Schema(description = "备注", example = "你说的对")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "创建者")
    @ExcelProperty("创建者")
    private String creator;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

    @Schema(description = "产品单位")
    private Long productUnitId;

    @Schema(description = "产品单位")
    @ExcelProperty("产品单位")
    private String productUnitName;

    @Schema(description = "产品分类")
    private Long productCategoryId;

    @Schema(description = "产品分类")
    @ExcelProperty("产品分类")
    private String productCategoryName;
}